import { Component, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router';

import { ITemporaryPosition } from 'app/shared/model/temporary-position.model';

@Component({
    selector: 'jhi-temporary-position-detail',
    templateUrl: './temporary-position-detail.component.html'
})
export class TemporaryPositionDetailComponent implements OnInit {
    temporaryPosition: ITemporaryPosition;

    constructor(protected activatedRoute: ActivatedRoute) {}

    ngOnInit() {
        this.activatedRoute.data.subscribe(({ temporaryPosition }) => {
            this.temporaryPosition = temporaryPosition;
        });
    }

    previousState() {
        window.history.back();
    }
}
